package panel

import "strings"

type Doer interface {
    Do(command string)
}

func Min(x, y int) int {
    if x < y { return x }
    return y
}

func Chop(command string) (fun, arg string) {
    i := strings.IndexRune(command, ' ')
    if i < 0 { return command, "" }
    return command[0:i], command[i+1:]
}